﻿{$header}
<div id="main" class="main" >
    <div class="content">
  <h3 class="heading">编辑发货单 [ <a href="__URL__">返回列表</a> ]</h3>
<div id="result" class="result none"></div>
 <div id="myTabContent" class="tab-content">
            
    <div class="tab-pane fade in active" id="home">

<form class="form-horizontal well" method='post' id="form1" action="__URL__/update/">
<table cellpadding=3 cellspacing=3 >
<tr>
	<td class="tRight" >发货单号：</td>
	<td class="tLeft" >{$vo.mano}   
        <input type="hidden" name="jumpUrl" value="__URL__">
    </td>
</tr>
<tr>
    <td class="tRight" >销售单号：</td>
    <td class="tLeft" >{$vo.order_id|getModelName='Order','mano'}</td>
</tr>
<php>$customer_id = getModelName($vo['order_id'],'Order','customer_id');</php>
<tr>
	<td class="tRight" >客户：</td>
	<td class="tLeft" ><a href="__APP__/Customer/edit/id/{$customer_id}" target="_blank">{$customer_id|getModelName='Customer'} </a></td>
</tr>
<tr>
    <td>地址：</td>
    <td>{$vo.order_id|getModelName='Order','address'}</td>
</tr>
<tr>
    <td>订单要求：</td>
    <td>{$vo.remark}</td>
</tr>

<tr>
    <td>毛重：</td>
    <td>{$vo.weight}</td>
</tr>
<tr>
    <td>净重：</td>
    <td>{$vo.net_weight}</td>
</tr>
<tr>
    <td>实际运费：</td>
    <td><input type="text" name="real_logifee" value="{$vo.real_logifee}"></td>
</tr>
<tr>
    <td>实际单位运价：</td>
    <td>{$vo.real_unit_logifee}</td>
</tr>
<tr>
    <td>理论美金运费：</td>
    <td><input type="text" name="us_logifee" value="{$us_logifee}"></td>
</tr>
<tr>
    <td>理论人民币运费</td>
    <td><input type="text" name="rmb_logifee" value="{$vo.rmb_logifee}"></td>
</tr>
<tr>
    <td>运费差额</td>
    <td>{$vo.logifee_diff}</td>
</tr>
<tr>
    <td>物流公司：</td>
    <td>{:configList(C('foreignlogi'),$vo['logi_id'],'logi_id')}</td>
</tr>
<tr>
    <td>物流单号：</td>
    <td>{$vo.logi_no}</td>
</tr>
<tr>
    <td>物流跟踪信息：</td>
    <td> {$vo.information}</td>
</tr>
<tr>
	<td class="tRight" >经办人：</td>
	<td class="tLeft" >{:modList('User')} {$vo.create_time|toDate}</td>
</tr>
<tr>
    <td>发货单状态：</td>
    <td>{$vo.status|getConfigVal='shippingStatus'}</td>
</tr>
<tr>
    <td>运费管理状态：</td>
    <td>{:configList(C('logifee_Status'),$vo['logifee_status'],'logifee_status')}</td>
</tr>
<tr>
	<td></td>
	<td class="center" width="300">
        <input type="hidden" value="{$vo.id}" name="id">
	<button type="submit" class="btn btn-primary"><i class="icon-ok icon-white"></i> 保存</button>
	<button type="reset" onclick="javascript:history.back()" class="btn btn-primary offset1"><i class="icon-arrow-left icon-white"></i> 返回</button>
	</td>
</tr>
</table>
</form>
<table class="table table-bordered table-striped">
            <tr><th>编号</th><th>销售分单号</th><th>运费</th> <th>订单要求</th> <th>产品中文</th><th>英文名称</th><th>CAS</th><th>数量</th><th>单价</th> <th>单位</th><th>货值</th> </tr>
            <volist name="products" id="ca">
                <tr>
                <td>{$ca.id}</td>

                <?php $order_detail = M('Order_detail')->getById($ca['order_detail_id']); ?>
                <td>{$order_detail.mano}</td>
                <td>{$order_detail.logifee}</td>
                <td>{$order_detail.order_id|getModelName='Order','remark'}</td>
                <php>
                    $product = M('Product');
                    $product->getById($ca['product_id']);
                </php>
                <td>{:$product->name}</td>
                <td>{:$product->ename}</td>
                <td>{:$product->cas}</td>
                <td>{$ca.number}</td>
                <td>{$order_detail.price}</td>
                <td>{$ca.order_detail_id|getModelName='Order_detail','unit_id'|getModelName='Unit'}</td>
                <td>{$ca.total}</td>
            </tr>
            </volist>
        </table>
</div>
</div>
</div>
<include file="Public:footer" />